package cat.inkubator.plugin4j.download;

import cat.inkubator.plugin4j.xml.Plugin;
import java.util.ArrayList;
import java.util.Vector;

/**
 *
 * @author gato
 */
public class DownloadManager {

    private Vector<Plugin> plugins;
    private String targetFolder;

    public DownloadManager( ArrayList<Plugin> arrayPlugins, String targetFolder ){
        
        this.plugins = new Vector( arrayPlugins );
        this.targetFolder = targetFolder;
        
    }

    public boolean startDownload(){
        DownloadMonitor monitor = new DownloadMonitor();
        monitor.download(getPlugins(), targetFolder);
        
        return true;
    }

    public Vector<Plugin> getPlugins() {
        return plugins;
    }

}
